package com.design.structure.facade.atguigu;

/**
 * @ProjectName: design
 * @Package: com.design.structure.facade.atguigu
 * @ClassName: DVDPlayer
 * @Author: shenaiguo
 * @Description:
 * @Date: 2020/9/8 0008 22:50
 */
// 步骤 1
public class DVDPlayer {
    //使用单例模式, 使用饿汉式
    private static DVDPlayer instance = new DVDPlayer();


    public static DVDPlayer getInstanc() {
        return instance;
    }


    public void on() {
        System.out.println(" dvd on ");
    }

    public void off() {
        System.out.println(" dvd off ");
    }


    public void play() {
        System.out.println(" dvd is playing ");
    }
    //....
    public void pause() { System.out.println(" dvd pause ..");
    }
}
